package  
{
	import net.flashpunk.Entity;
	import net.flashpunk.graphics.Image;
	import net.flashpunk.masks.Pixelmask;
	import net.flashpunk.FP;
	/**
	 * ...
	 * @author Donatello
	 */
	public class LineGuy extends Entity
	{
		[Embed(source = "img/line/lineGuy1.png")]	private const IMG_LINE1:Class;
		[Embed(source = "img/line/lineGuy2.png")]	private const IMG_LINE2:Class;
		[Embed(source = "img/line/lineGuy3.png")]	private const IMG_LINE3:Class;
		[Embed(source = "img/line/lineGuy4.png")]	private const IMG_LINE4:Class;
		[Embed(source = "img/line/lineGuy5.png")]	private const IMG_LINE5:Class;

		private var imgLine:Image;
	
		
		public function LineGuy(px:Number=305,py:Number=500, t:int=10) 
		{
			if(t==10)
			{
				switch(FP.rand(5))
				{
					case 0:imgLine = new Image(IMG_LINE1); mask = new Pixelmask(IMG_LINE1); break;
					case 1:imgLine = new Image(IMG_LINE2); mask = new Pixelmask(IMG_LINE2); break;
					case 2:imgLine = new Image(IMG_LINE3); mask = new Pixelmask(IMG_LINE3); break;
					case 3:imgLine = new Image(IMG_LINE4); mask = new Pixelmask(IMG_LINE4); break;
					case 4:imgLine = new Image(IMG_LINE5); mask = new Pixelmask(IMG_LINE5); break;
				}
			}
			else
			{
				switch(t)
				{
					case 0:imgLine = new Image(IMG_LINE1); mask = new Pixelmask(IMG_LINE1); break;
					case 1:imgLine = new Image(IMG_LINE2); mask = new Pixelmask(IMG_LINE2); break;
					case 2:imgLine = new Image(IMG_LINE3); mask = new Pixelmask(IMG_LINE3); break;
					case 3:imgLine = new Image(IMG_LINE4); mask = new Pixelmask(IMG_LINE4); break;
					case 4:imgLine = new Image(IMG_LINE5); mask = new Pixelmask(IMG_LINE5); break;
				}
				
				
			
			}
			
		
			graphic=imgLine;
			
			type = "LineGuy";
			
			x = px;
			y = py;
			
		}
		
	}

}